#include "PlanetManager.h"


PlanetManager::PlanetManager(void)
{
}


PlanetManager::~PlanetManager(void)
{
}

void PlanetManager::Init(SceneManager* sMgr)
{
	sceneMgr=sMgr;
	planet=new Planet(50);
	SetupContent();
}
void PlanetManager::SetupContent()
{
	
	sceneMgr->setAmbientLight(ColourValue(0.5, 0.5, 0.5));

	Entity *ent = sceneMgr->createEntity("Commet", "commet.mesh");
	SceneNode *node = sceneMgr->getRootSceneNode()->createChildSceneNode("PlanetNode");
	node->attachObject(ent);
	planet->node=node;

	node = sceneMgr->getRootSceneNode()->createChildSceneNode("StarboxNode");
	ent = sceneMgr->createEntity("Starbox", "starbox1.mesh");
	node->attachObject(ent);

	Light *light = sceneMgr->createLight("PointLight");
	light->setType(Ogre::Light::LT_POINT);
	light->setPosition(Ogre::Vector3(250, 150, 250));
	light->setDiffuseColour(Ogre::ColourValue::White);
	light->setSpecularColour(Ogre::ColourValue::White);

}

void PlanetManager::AddTime(Real deltaTime)
{

}